Optimal. Leaf size=107 \[ \frac{(3 A+B) \tanh ^{-1}\left (\frac{\sqrt{a} \sin (c+d x) \sqrt{\sec (c+d x)}}{\sqrt{2} \sqrt{a \sec (c+d x)+a}}\right )}{2 \sqrt{2} a^{3/2} d}-\frac{(A-B) \sin (c+d x) \sec ^{\frac{3}{2}}(c+d x)}{2 d (a \sec (c+d x)+a)^{3/2}} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.194627, antiderivative size = 107, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 3, integrand size = 35, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.086, Rules used = {4012, 3808, 206} \[ \frac{(3 A+B) \tanh ^{-1}\left (\frac{\sqrt{a} \sin (c+d x) \sqrt{\sec (c+d x)}}{\sqrt{2} \sqrt{a \sec (c+d x)+a}}\right )}{2 \sqrt{2} a^{3/2} d}-\frac{(A-B) \sin (c+d x) \sec ^{\frac{3}{2}}(c+d x)}{2 d (a \sec (c+d x)+a)^{3/2}} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 4012
Rule 3808
Rule 206
Rubi steps
\begin{align*} \int \frac{\sqrt{\sec (c+d x)} (A+B \sec (c+d x))}{(a+a \sec (c+d x))^{3/2}} \, dx &=-\frac{(A-B) \sec ^{\frac{3}{2}}(c+d x) \sin (c+d x)}{2 d (a+a \sec (c+d x))^{3/2}}+\frac{(3 A+B) \int \frac{\sqrt{\sec (c+d x)}}{\sqrt{a+a \sec (c+d x)}} \, dx}{4 a}\\ &=-\frac{(A-B) \sec ^{\frac{3}{2}}(c+d x) \sin (c+d x)}{2 d (a+a \sec (c+d x))^{3/2}}-\frac{(3 A+B) \operatorname{Subst}\left (\int \frac{1}{2 a-x^2} \, dx,x,-\frac{a \sqrt{\sec (c+d x)} \sin (c+d x)}{\sqrt{a+a \sec (c+d x)}}\right )}{2 a d}\\ &=\frac{(3 A+B) \tanh ^{-1}\left (\frac{\sqrt{a} \sqrt{\sec (c+d x)} \sin (c+d x)}{\sqrt{2} \sqrt{a+a \sec (c+d x)}}\right )}{2 \sqrt{2} a^{3/2} d}-\frac{(A-B) \sec ^{\frac{3}{2}}(c+d x) \sin (c+d x)}{2 d (a+a \sec (c+d x))^{3/2}}\\ \end{align*}
Mathematica [A] time = 0.21888, size = 84, normalized size = 0.79 \[ \frac{\cos \left (\frac{1}{2} (c+d x)\right ) \sec ^{\frac{3}{2}}(c+d x) \left ((B-A) \sin \left (\frac{1}{2} (c+d x)\right )+(3 A+B) \cos ^2\left (\frac{1}{2} (c+d x)\right ) \tanh ^{-1}\left (\sin \left (\frac{1}{2} (c+d x)\right )\right )\right )}{d (a (\sec (c+d x)+1))^{3/2}} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] time = 0.292, size = 219, normalized size = 2.1 \begin{align*}{\frac{\cos \left ( dx+c \right ) \left ( \left ( \cos \left ( dx+c \right ) \right ) ^{2}-1 \right ) }{4\,d{a}^{2} \left ( \sin \left ( dx+c \right ) \right ) ^{3}}\sqrt{ \left ( \cos \left ( dx+c \right ) \right ) ^{-1}}\sqrt{{\frac{a \left ( \cos \left ( dx+c \right ) +1 \right ) }{\cos \left ( dx+c \right ) }}} \left ( A\cos \left ( dx+c \right ) \sqrt{-2\, \left ( \cos \left ( dx+c \right ) +1 \right ) ^{-1}}+3\,A\arctan \left ( 1/2\,\sin \left ( dx+c \right ) \sqrt{-2\, \left ( \cos \left ( dx+c \right ) +1 \right ) ^{-1}} \right ) \sin \left ( dx+c \right ) -B\cos \left ( dx+c \right ) \sqrt{-2\, \left ( \cos \left ( dx+c \right ) +1 \right ) ^{-1}}+B\arctan \left ({\frac{\sin \left ( dx+c \right ) }{2}\sqrt{-2\, \left ( \cos \left ( dx+c \right ) +1 \right ) ^{-1}}} \right ) \sin \left ( dx+c \right ) -A\sqrt{-2\, \left ( \cos \left ( dx+c \right ) +1 \right ) ^{-1}}+B\sqrt{-2\, \left ( \cos \left ( dx+c \right ) +1 \right ) ^{-1}} \right ) \sqrt{-2\, \left ( \cos \left ( dx+c \right ) +1 \right ) ^{-1}}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-1)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 0.513246, size = 995, normalized size = 9.3 \begin{align*} \left [\frac{\sqrt{2}{\left ({\left (3 \, A + B\right )} \cos \left (d x + c\right )^{2} + 2 \,{\left (3 \, A + B\right )} \cos \left (d x + c\right ) + 3 \, A + B\right )} \sqrt{a} \log \left (-\frac{a \cos \left (d x + c\right )^{2} - 2 \, \sqrt{2} \sqrt{a} \sqrt{\frac{a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \sqrt{\cos \left (d x + c\right )} \sin \left (d x + c\right ) - 2 \, a \cos \left (d x + c\right ) - 3 \, a}{\cos \left (d x + c\right )^{2} + 2 \, \cos \left (d x + c\right ) + 1}\right ) - 4 \,{\left (A - B\right )} \sqrt{\frac{a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \sqrt{\cos \left (d x + c\right )} \sin \left (d x + c\right )}{8 \,{\left (a^{2} d \cos \left (d x + c\right )^{2} + 2 \, a^{2} d \cos \left (d x + c\right ) + a^{2} d\right )}}, -\frac{\sqrt{2}{\left ({\left (3 \, A + B\right )} \cos \left (d x + c\right )^{2} + 2 \,{\left (3 \, A + B\right )} \cos \left (d x + c\right ) + 3 \, A + B\right )} \sqrt{-a} \arctan \left (\frac{\sqrt{2} \sqrt{-a} \sqrt{\frac{a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \sqrt{\cos \left (d x + c\right )}}{a \sin \left (d x + c\right )}\right ) + 2 \,{\left (A - B\right )} \sqrt{\frac{a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \sqrt{\cos \left (d x + c\right )} \sin \left (d x + c\right )}{4 \,{\left (a^{2} d \cos \left (d x + c\right )^{2} + 2 \, a^{2} d \cos \left (d x + c\right ) + a^{2} d\right )}}\right ] \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{{\left (B \sec \left (d x + c\right ) + A\right )} \sqrt{\sec \left (d x + c\right )}}{{\left (a \sec \left (d x + c\right ) + a\right )}^{\frac{3}{2}}}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]